﻿using System.IO;
using System.Threading.Tasks;

namespace Sys.Excel
{
    public static class IExcelExporterExtensions
    {
        public static Task BuildSheetsAsync(this IExcelExporter exporter, Stream stream, bool useOldVersion, params Settings[] settingsArray)
        {
            return exporter.BuildSheetsAsync(stream, settingsArray, useOldVersion);
        }

        public static Task BuildSheetsAsync_2003(this IExcelExporter exporter, Stream stream, params Settings[] settingsArray)
        {
            return exporter.BuildSheetsAsync(stream, settingsArray, true);
        }

        public static Task BuildSheetsAsync_2007(this IExcelExporter exporter, Stream stream, params Settings[] settingsArray)
        {
            return exporter.BuildSheetsAsync(stream, settingsArray);
        }
    }
}